package com.lk.lkappearance.model;

import java.io.Serializable;

/**
 * meter
 * @author 
 */
public class Meter implements Serializable {
    /**
     * 主键ID
     */
    private String meterId;

    /**
     * 仪表名称
     */
    private String meterName;

    /**
     * 仪表类型
     */
    private Integer meterType;

    /**
     * 仪表编号
     */
    private String meterNumber;

    /**
     * 仪表厂家
     */
    private String meterFactory;

    /**
     * 仪表型号
     */
    private String meterModel;

    /**
     * 介质类型,取自字典表
     */
    private String mediaType;

    /**
     * 地理位置
     */
    private String location;

    /**
     * 供给/消耗
     */
    private String supplyDeplete;

    /**
     * 仪表状态,取自字典表
     */
    private String meterStatus;

    /**
     * 可以有多个父表id,用逗号隔开
     */
    private String parentIds;

    /**
     * 可以有多个子表id,用逗号隔开
     */
    private String childIds;

    /**
     * 如果是主表,填对应辅表id,否则为空
     */
    private String auxiliaryId;

    /**
     * ABC
     */
    private String meterImportance;

    /**
     * 串口服务器IP
     */
    private String serverIp;

    /**
     * 从站地址
     */
    private Integer slaveAddress;

    private static final long serialVersionUID = 1L;

    public String getMeterId() {
        return meterId;
    }

    public void setMeterId(String meterId) {
        this.meterId = meterId;
    }

    public String getMeterName() {
        return meterName;
    }

    public void setMeterName(String meterName) {
        this.meterName = meterName;
    }

    public Integer getMeterType() {
        return meterType;
    }

    public void setMeterType(Integer meterType) {
        this.meterType = meterType;
    }

    public String getMeterNumber() {
        return meterNumber;
    }

    public void setMeterNumber(String meterNumber) {
        this.meterNumber = meterNumber;
    }

    public String getMeterFactory() {
        return meterFactory;
    }

    public void setMeterFactory(String meterFactory) {
        this.meterFactory = meterFactory;
    }

    public String getMeterModel() {
        return meterModel;
    }

    public void setMeterModel(String meterModel) {
        this.meterModel = meterModel;
    }

    public String getMediaType() {
        return mediaType;
    }

    public void setMediaType(String mediaType) {
        this.mediaType = mediaType;
    }

    public String getLocation() {
        return location;
    }

    public void setLocation(String location) {
        this.location = location;
    }

    public String getSupplyDeplete() {
        return supplyDeplete;
    }

    public void setSupplyDeplete(String supplyDeplete) {
        this.supplyDeplete = supplyDeplete;
    }

    public String getMeterStatus() {
        return meterStatus;
    }

    public void setMeterStatus(String meterStatus) {
        this.meterStatus = meterStatus;
    }

    public String getParentIds() {
        return parentIds;
    }

    public void setParentIds(String parentIds) {
        this.parentIds = parentIds;
    }

    public String getChildIds() {
        return childIds;
    }

    public void setChildIds(String childIds) {
        this.childIds = childIds;
    }

    public String getAuxiliaryId() {
        return auxiliaryId;
    }

    public void setAuxiliaryId(String auxiliaryId) {
        this.auxiliaryId = auxiliaryId;
    }

    public String getMeterImportance() {
        return meterImportance;
    }

    public void setMeterImportance(String meterImportance) {
        this.meterImportance = meterImportance;
    }

    public String getServerIp() {
        return serverIp;
    }

    public void setServerIp(String serverIp) {
        this.serverIp = serverIp;
    }

    public Integer getSlaveAddress() {
        return slaveAddress;
    }

    public void setSlaveAddress(Integer slaveAddress) {
        this.slaveAddress = slaveAddress;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Meter other = (Meter) that;
        return (this.getMeterId() == null ? other.getMeterId() == null : this.getMeterId().equals(other.getMeterId()))
            && (this.getMeterName() == null ? other.getMeterName() == null : this.getMeterName().equals(other.getMeterName()))
            && (this.getMeterType() == null ? other.getMeterType() == null : this.getMeterType().equals(other.getMeterType()))
            && (this.getMeterNumber() == null ? other.getMeterNumber() == null : this.getMeterNumber().equals(other.getMeterNumber()))
            && (this.getMeterFactory() == null ? other.getMeterFactory() == null : this.getMeterFactory().equals(other.getMeterFactory()))
            && (this.getMeterModel() == null ? other.getMeterModel() == null : this.getMeterModel().equals(other.getMeterModel()))
            && (this.getMediaType() == null ? other.getMediaType() == null : this.getMediaType().equals(other.getMediaType()))
            && (this.getLocation() == null ? other.getLocation() == null : this.getLocation().equals(other.getLocation()))
            && (this.getSupplyDeplete() == null ? other.getSupplyDeplete() == null : this.getSupplyDeplete().equals(other.getSupplyDeplete()))
            && (this.getMeterStatus() == null ? other.getMeterStatus() == null : this.getMeterStatus().equals(other.getMeterStatus()))
            && (this.getParentIds() == null ? other.getParentIds() == null : this.getParentIds().equals(other.getParentIds()))
            && (this.getChildIds() == null ? other.getChildIds() == null : this.getChildIds().equals(other.getChildIds()))
            && (this.getAuxiliaryId() == null ? other.getAuxiliaryId() == null : this.getAuxiliaryId().equals(other.getAuxiliaryId()))
            && (this.getMeterImportance() == null ? other.getMeterImportance() == null : this.getMeterImportance().equals(other.getMeterImportance()))
            && (this.getServerIp() == null ? other.getServerIp() == null : this.getServerIp().equals(other.getServerIp()))
            && (this.getSlaveAddress() == null ? other.getSlaveAddress() == null : this.getSlaveAddress().equals(other.getSlaveAddress()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getMeterId() == null) ? 0 : getMeterId().hashCode());
        result = prime * result + ((getMeterName() == null) ? 0 : getMeterName().hashCode());
        result = prime * result + ((getMeterType() == null) ? 0 : getMeterType().hashCode());
        result = prime * result + ((getMeterNumber() == null) ? 0 : getMeterNumber().hashCode());
        result = prime * result + ((getMeterFactory() == null) ? 0 : getMeterFactory().hashCode());
        result = prime * result + ((getMeterModel() == null) ? 0 : getMeterModel().hashCode());
        result = prime * result + ((getMediaType() == null) ? 0 : getMediaType().hashCode());
        result = prime * result + ((getLocation() == null) ? 0 : getLocation().hashCode());
        result = prime * result + ((getSupplyDeplete() == null) ? 0 : getSupplyDeplete().hashCode());
        result = prime * result + ((getMeterStatus() == null) ? 0 : getMeterStatus().hashCode());
        result = prime * result + ((getParentIds() == null) ? 0 : getParentIds().hashCode());
        result = prime * result + ((getChildIds() == null) ? 0 : getChildIds().hashCode());
        result = prime * result + ((getAuxiliaryId() == null) ? 0 : getAuxiliaryId().hashCode());
        result = prime * result + ((getMeterImportance() == null) ? 0 : getMeterImportance().hashCode());
        result = prime * result + ((getServerIp() == null) ? 0 : getServerIp().hashCode());
        result = prime * result + ((getSlaveAddress() == null) ? 0 : getSlaveAddress().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", meterId=").append(meterId);
        sb.append(", meterName=").append(meterName);
        sb.append(", meterType=").append(meterType);
        sb.append(", meterNumber=").append(meterNumber);
        sb.append(", meterFactory=").append(meterFactory);
        sb.append(", meterModel=").append(meterModel);
        sb.append(", mediaType=").append(mediaType);
        sb.append(", location=").append(location);
        sb.append(", supplyDeplete=").append(supplyDeplete);
        sb.append(", meterStatus=").append(meterStatus);
        sb.append(", parentIds=").append(parentIds);
        sb.append(", childIds=").append(childIds);
        sb.append(", auxiliaryId=").append(auxiliaryId);
        sb.append(", meterImportance=").append(meterImportance);
        sb.append(", serverIp=").append(serverIp);
        sb.append(", slaveAddress=").append(slaveAddress);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }

    public Meter() {
    }

    public Meter(String meterId, String meterName, Integer meterType, String meterNumber, String meterFactory, String meterModel, String mediaType, String location, String supplyDeplete, String meterStatus, String parentIds, String childIds, String auxiliaryId, String meterImportance, String serverIp, Integer slaveAddress) {
        this.meterId = meterId;
        this.meterName = meterName;
        this.meterType = meterType;
        this.meterNumber = meterNumber;
        this.meterFactory = meterFactory;
        this.meterModel = meterModel;
        this.mediaType = mediaType;
        this.location = location;
        this.supplyDeplete = supplyDeplete;
        this.meterStatus = meterStatus;
        this.parentIds = parentIds;
        this.childIds = childIds;
        this.auxiliaryId = auxiliaryId;
        this.meterImportance = meterImportance;
        this.serverIp = serverIp;
        this.slaveAddress = slaveAddress;
    }
}